package com.sf.sgs.sessionevaluate.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import org.springframework.transaction.annotation.Transactional;

import com.sf.sgs.sessionevaluate.dao.ISessionAnswerDao;
import com.sf.sgs.sessionevaluate.domain.SessionAnswer;
import com.sf.sgs.sessionevaluate.service.ISessionAnswerService;

@Component
@Transactional
public class SessionAnswerServiceImpl implements ISessionAnswerService {
	@Autowired
	private ISessionAnswerDao sessionAnswerDao;

	@Override
	public SessionAnswer getById(Long id) {
		if (id == null) {
			return null;
		}
		return sessionAnswerDao.findOne(id);
	}

	@Override
	public SessionAnswer save(SessionAnswer sessionAnswer) {
		return sessionAnswerDao.save(sessionAnswer);
	}

}
